<h1>Edit Technology : <?php echo $info[0]->title; ?></h1>

<div class = "page">
  
</div>

<div class = "clear"></div>

<form method="post" action="<?php echo base_url(); ?>admin/technology/edit/process" class = "form" enctype="multipart/form-data">

  <input type="hidden" name="id" value="<?php echo $info[0]->id; ?>" />
  
  <div class = "field"><label>Title</label><input type = "text" name = "title" class = "input size1" value="<?php echo $info[0]->title; ?>" /></div>
  
  <div class = "field"><label>Date</label><input type = "text" name = "date" class = "input size1 datepicker" value="<?php echo date('Y-m-d',$info[0]->date); ?>" /></div>
  
  <div class = "field"><label>Picture</label><input type = "file" name = "img" class = "input size1" > * 156x100 pixel
  <?php
    if($info[0]->img!='' AND file_exists(APPPATH.'../assets/image/technology/'.$info[0]->id.'/'.$info[0]->img)){
      $url = base_url();
      echo <<<ddd
      <div class = "field">
        <label>&nbsp;</label>
        <img src="{$url}assets/image/technology/{$info[0]->id}/{$info[0]->img}" />
      </div>
ddd;
    }
  ?>
  
  <div class = "field">
    <label>Detail</label>
    <textarea name = "detail" class = "mceNoEditor"><?php echo $info[0]->detail; ?></textarea>
    <div class = "clear"></div>
  </div>
  
  <hr>
  <div class = "field"><label></label><input type = "submit" value = "Update" class = "btn">&nbsp;<a href = "#" class = "btn" onclick="javascript:history.back(1)">Cancel</a></div>
    <div class = "field error_msg"><label></label><?php echo $message; ?></div>
</form>

</div>

<style>
  .form label {
    width:80px;
  }
  textarea.mceNoEditor{
    width: 400px;    
    height: 150px;    
  }
</style>
<script>
  $(document).ready(function(){
    $('.datepicker').datepicker({
      dateFormat: 'yy-mm-dd',
      changeMonth: true,
      changeYear: true
    });
  });
</script>